<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>

<head>
    <title>活动审批页面</title>
    <link rel="stylesheet" href="../plugins/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/AdminLTE.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/skins/_all-skins.min.css">
    <link rel="stylesheet" href="../css/style.css">
    <link rel="script" href="../plugins/jQuery/jquery-2.2.3.min.js">
</head>

<body class="hold-transition skin-purple sidebar-mini">

<div class="wrapper">
    <!-- 页面头部 -->
    <jsp:include page="header.jsp"></jsp:include>
    <!-- 页面头部 /-->
    <!-- 导航侧栏 -->
    <jsp:include page="aside.jsp"></jsp:include>
    <!-- 导航侧栏 /-->

    <!-- 内容区域 -->
    <div class="content-wrapper">
        <section class="content">
            <div class="box box-primary">
                <div class="box-header with-border">
                    <i class="fa fa-cube"></i>
                    <h3 class="box-title">待处理活动</h3>
                </div>
                <div class="box-body">
                    <div class="table-box">
                        <!--数据列表-->
                        <div class="table-box">
                            <!--工具栏-->
                            <div class="pull-left">
                                <div class="form-group form-inline">
                                    <div class="btn-group">
                                        <a href="${pageContext.request.contextPath}/ActivityServlet?method=findActivityApprove&status=0"><i class="fa fa-refresh"></i>刷新</a>
                                    </div>
                                </div>
                            </div>
                        <table id="dataList" class="table table-bordered table-striped table-hover dataTable">
                            <thead>
                            <tr>
                                <th class="">活动名称</th>
                                <th class="">活动介绍</th>
                                <th class="">预算信息</th>
                                <th class="">活动时间</th>
                                <th class="">活动地点</th>
                                <th class="text-center">同意举办</th>
                                <th class="text-center">不同意举办</th>
                            </tr>
                            </thead>
                            <tbody>
                            <c:forEach items="${activities}" var="a">
                            <tr>
                                <td>${a.aname}</td>
                                <td>${a.aintroduce}</td>
                                <td>${a.budget}</td>
                                <td>${a.atime}</td>
                                <td>${a.aplace}</td>
                                <td class="text-center">
                                    <a href="${pageContext.request.contextPath}/ActivityServlet?method=activityApprove&aid=${a.aid}&result=1" class="btn bg-olive btn-xs">同意</a>
                                </td>
                                <td class="text-center">
                                    <a href="${pageContext.request.contextPath}/ActivityServlet?method=activityApprove&aid=${a.aid}&result=0" class="btn bg-olive btn-xs">不同意</a>
                                </td>
                            </tr>
                            </c:forEach>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
            </div>
        </section>

    </div>
    <!-- 内容区域 /-->
    <!-- 底部导航 -->
   <jsp:include page="footer.jsp"></jsp:include>

</div>
<script src="../plugins/jQuery/jquery-2.2.3.min.js"></script>
<script src="../plugins/jQueryUI/jquery-ui.min.js"></script>
<script src="../plugins/bootstrap/js/bootstrap.min.js"></script>
<script src="../plugins/adminLTE/js/app.min.js"></script>
<script>
    // 设置激活菜单
    function setSidebarActive(tagUri) {
        var liObj = $("#" + tagUri);
        if (liObj.length > 0) {
            liObj.parent().parent().addClass("active");
            liObj.addClass("active");
        }
    }
    $(document).ready(function() {
        // 激活导航位置
        setSidebarActive("admin-index");
    });
</script>
</body>
</html>
